package com.yuan.yblog.crud.entity;

import java.io.Serial;
import com.baomidou.mybatisplus.annotation.*;
import java.io.Serializable;
import java.util.Date;
import com.baomidou.mybatisplus.annotation.TableId;
import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Data;

/**
* @author hepeiyuan
* @date 2024-06-04
*/
@Data
@TableName("comment")
@Schema(description = "文章评论表")
public class Comment implements Serializable {
    @Serial
    private static final long serialVersionUID = 1L;

    @Schema(description = "主键ID")
    @TableId(value = "id", type = IdType.AUTO)
    private Long id;

    @Schema(description = "评论的内容")
    private String content;

    @Schema(description = "回复的评论ID")
    private Long parentId;

    @Schema(description = "所属文章ID")
    private Long postId;

    @Schema(description = "评论的用户ID")
    private Long userId;

    @Schema(description = "“顶”的数量")
    private Integer voteUp;

    @Schema(description = "“踩”的数量")
    private Integer voteDown;

    @Schema(description = "置顶等级，0最高置顶，最低100")
    private Integer level;

    @Schema(description = "评论的状态，1可用，0不可用")
    private Integer status;

    @Schema(description = "评论的时间")
    private Date created;

    @Schema(description = "评论的更新时间")
    private Date modified;

}